﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.Master" AutoEventWireup="true"
    CodeBehind="KhachHang.aspx.cs" Inherits="XuaNhapKho.KhachHang" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="breadLine">
        <ul class="breadcrumb">
            <li><a href="#">Hệ thống quản lý xuất nhập kho</a> <span class="divider">></span></li>
            <li class="active">Quản lý khách hàng</li>
        </ul>
    </div>
    <div class="workplace">
        <div class="row-fluid">
            <div class="span4">
                <div class="head">
                    <div class="isw-grid">
                    </div>
                    <h1>
                        Thông tin khách hàng</h1>
                    <div class="clear">
                    </div>
                </div>
                <div class="block-fluid">
                    <div class="row-form">
                        <div class="span3">
                            Tên KH:
                        </div>
                        <div class="span9">
                            <asp:TextBox ID="txtTenKhachHang" runat="server" placeholder="Khách hàng..."></asp:TextBox></div>                            
                        <div class="clear">
                        </div>
                    </div>
                   
                    <div class="row-form">
                        <div class="span3">
                            Email:
                        </div>
                        <div class="span9">
                             <asp:TextBox ID="txtEmail" runat="server" placeholder="Email..."></asp:TextBox></div>   
                        <div class="clear">
                        </div>
                    </div>
                    <div class="row-form">
                        <div class="span3">
                            <span style="font-size : 9px;">Số điện thoại:</span>
                        </div>
                        <div class="span9">
                             <asp:TextBox ID="txtSoDienThoai" runat="server" placeholder="Số điện thoại..."></asp:TextBox></div>   
                        <div class="clear">
                        </div>
                    </div>
                     <div class="row-form">
                        <div class="span3">
                           Địa chỉ:
                        </div>
                        <div class="span9">
                             <asp:TextBox ID="txtDiaChi" runat="server" placeholder="Địa chỉ..."></asp:TextBox></div>   
                        <div class="clear">
                        </div>
                    </div>
                   
                    <div class="row-form">
                        <div class="span3">
                        </div>
                        <div class="span9">
                             <asp:Button  class="btn" Height="30px" ID="btnSave" runat="server" 
                                Text="Lưu lại" onclick="btnSave_Click"/>
                            <button class="btn">
                                Hủy bỏ</button>
                        </div>
                        <div class="clear">
                        </div>
                    </div>
                </div>
            </div>
            <div class="span8">
                <div class="head">
                    <div class="isw-grid">
                    </div>
                    <h1>
                        Danh sách khách hàng</h1>
                    <div class="clear">
                    </div>
                </div>
                <div class="block-fluid">
                    <asp:GridView CssClass="table" runat="server" 
                        BorderStyle="None" GridLines="None"  ID="grvKhachHang" runat="server" AutoGenerateColumns="False" 
                        onpageindexchanging="grvKhachHang_PageIndexChanging"> 
                       
                        <Columns>
                            <asp:BoundField DataField="TenKhachHang" HeaderText="Tên khách hàng" />
                            <asp:BoundField DataField="Email" HeaderText="Email" />
                            <asp:BoundField DataField="SoDienThoai" HeaderText="Số điện thoại" />
                            <asp:BoundField DataField="DiaChi" HeaderText="Địa chỉ" />
                          
                            <asp:TemplateField HeaderText="Chức năng">
                                <ItemTemplate>
                                    <asp:LinkButton ID="lbtnEdit" runat="server" 
                                        CommandArgument='<%# Eval("MaKhachHang") %>' oncommand="lbtnEdit_Command">Sửa</asp:LinkButton>
                                    &nbsp;|
                                    <asp:LinkButton ID="lbtnRemove" runat="server" 
                                        CommandArgument='<%# Eval("MaKhachHang") %>' OnClientClick="return confirm('Bạn có thực sự muốn xóa không ?')" oncommand="lbtnRemove_Command">Xóa</asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle Width="100px" HorizontalAlign="Center" />
                            </asp:TemplateField>

                        </Columns>
                    </asp:GridView>
                </div>
            </div>
        </div>
    </div>
</asp:Content>
